3.47 \(\int \frac {1+2 x^2}{1+4 x^4} \, dx\)

Optimal. Leaf size=21 \[ \frac {1}{2} \tan ^{-1}(2 x+1)-\frac {1}{2} \tan ^{-1}(1-2 x) \]

[Out]

1/2*arctan(-1+2*x)+1/2*arctan(1+2*x)

________________________________________________________________________________________

Rubi [A]  time = 0.01, antiderivative size = 21, normalized size of antiderivative = 1.00, number of steps used = 5, number of rules used = 3, integrand size = 17, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.176, Rules used = {1162, 617, 204} \[ \frac {1}{2} \tan ^{-1}(2 x+1)-\frac {1}{2} \tan ^{-1}(1-2 x) \]

Antiderivative was successfully verified.

[In]

Int[(1 + 2*x^2)/(1 + 4*x^4),x]

[Out]

-ArcTan[1 - 2*x]/2 + ArcTan[1 + 2*x]/2

Rule 204

Int[((a_) + (b_.)*(x_)^2)^(-1), x_Symbol] :> -Simp[ArcTan[(Rt[-b, 2]*x)/Rt[-a, 2]]/(Rt[-a, 2]*Rt[-b, 2]), x] /
; FreeQ[{a, b}, x] && PosQ[a/b] && (LtQ[a, 0] || LtQ[b, 0])

Rule 617

Int[((a_) + (b_.)*(x_) + (c_.)*(x_)^2)^(-1), x_Symbol] :> With[{q = 1 - 4*Simplify[(a*c)/b^2]}, Dist[-2/b, Sub
st[Int[1/(q - x^2), x], x, 1 + (2*c*x)/b], x] /; RationalQ[q] && (EqQ[q^2, 1] ||  !RationalQ[b^2 - 4*a*c])] /;
 FreeQ[{a, b, c}, x] && NeQ[b^2 - 4*a*c, 0]

Rule 1162

Int[((d_) + (e_.)*(x_)^2)/((a_) + (c_.)*(x_)^4), x_Symbol] :> With[{q = Rt[(2*d)/e, 2]}, Dist[e/(2*c), Int[1/S
imp[d/e + q*x + x^2, x], x], x] + Dist[e/(2*c), Int[1/Simp[d/e - q*x + x^2, x], x], x]] /; FreeQ[{a, c, d, e},
 x] && EqQ[c*d^2 - a*e^2, 0] && PosQ[d*e]

Rubi steps

\begin {align*} \int \frac {1+2 x^2}{1+4 x^4} \, dx &=\frac {1}{4} \int \frac {1}{\frac {1}{2}-x+x^2} \, dx+\frac {1}{4} \int \frac {1}{\frac {1}{2}+x+x^2} \, dx\\ &=\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,1-2 x\right )-\frac {1}{2} \operatorname {Subst}\left (\int \frac {1}{-1-x^2} \, dx,x,1+2 x\right )\\ &=-\frac {1}{2} \tan ^{-1}(1-2 x)+\frac {1}{2} \tan ^{-1}(1+2 x)\\ \end {align*}

________________________________________________________________________________________

Mathematica [A]  time = 0.01, size = 17, normalized size = 0.81 \[ -\frac {1}{2} \tan ^{-1}\left (\frac {2 x}{2 x^2-1}\right ) \]

Antiderivative was successfully verified.

[In]

Integrate[(1 + 2*x^2)/(1 + 4*x^4),x]

[Out]

-1/2*ArcTan[(2*x)/(-1 + 2*x^2)]

________________________________________________________________________________________

fricas [A]  time = 0.42, size = 15, normalized size = 0.71 \[ \frac {1}{2} \, \arctan \left (2 \, x^{3} + x\right ) + \frac {1}{2} \, \arctan \relax (x) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+1)/(4*x^4+1),x, algorithm="fricas")

[Out]

1/2*arctan(2*x^3 + x) + 1/2*arctan(x)

________________________________________________________________________________________

giac [B]  time = 0.16, size = 46, normalized size = 2.19 \[ \frac {1}{2} \, \arctan \left (2 \, \sqrt {2} \left (\frac {1}{4}\right )^{\frac {3}{4}} {\left (2 \, x + \sqrt {2} \left (\frac {1}{4}\right )^{\frac {1}{4}}\right )}\right ) + \frac {1}{2} \, \arctan \left (2 \, \sqrt {2} \left (\frac {1}{4}\right )^{\frac {3}{4}} {\left (2 \, x - \sqrt {2} \left (\frac {1}{4}\right )^{\frac {1}{4}}\right )}\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+1)/(4*x^4+1),x, algorithm="giac")

[Out]

1/2*arctan(2*sqrt(2)*(1/4)^(3/4)*(2*x + sqrt(2)*(1/4)^(1/4))) + 1/2*arctan(2*sqrt(2)*(1/4)^(3/4)*(2*x - sqrt(2
)*(1/4)^(1/4)))

________________________________________________________________________________________

maple [A]  time = 0.01, size = 18, normalized size = 0.86 \[ \frac {\arctan \left (2 x +1\right )}{2}+\frac {\arctan \left (2 x -1\right )}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^2+1)/(4*x^4+1),x)

[Out]

1/2*arctan(2*x-1)+1/2*arctan(2*x+1)

________________________________________________________________________________________

maxima [A]  time = 2.24, size = 17, normalized size = 0.81 \[ \frac {1}{2} \, \arctan \left (2 \, x + 1\right ) + \frac {1}{2} \, \arctan \left (2 \, x - 1\right ) \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x^2+1)/(4*x^4+1),x, algorithm="maxima")

[Out]

1/2*arctan(2*x + 1) + 1/2*arctan(2*x - 1)

________________________________________________________________________________________

mupad [B]  time = 4.29, size = 15, normalized size = 0.71 \[ \frac {\mathrm {atan}\left (2\,x^3+x\right )}{2}+\frac {\mathrm {atan}\relax (x)}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

int((2*x^2 + 1)/(4*x^4 + 1),x)

[Out]

atan(x + 2*x^3)/2 + atan(x)/2

________________________________________________________________________________________

sympy [A]  time = 0.11, size = 14, normalized size = 0.67 \[ \frac {\operatorname {atan}{\relax (x )}}{2} + \frac {\operatorname {atan}{\left (2 x^{3} + x \right )}}{2} \]

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate((2*x**2+1)/(4*x**4+1),x)

[Out]

atan(x)/2 + atan(2*x**3 + x)/2

________________________________________________________________________________________